<%-- 
    Document   : grammar
    Created on : 7/Abr/2010, 22:57:48
    Author     : luis
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"
    import="pt.our.angemc.parser.*"
    import="org.json.*"
%>

<%
    String text = request.getParameter("text");
    Parser2 p = new Parser2();
    String res = p.checkGrammar(text);

    JSONObject obj = new JSONObject();
    obj.put("success", true);
    obj.put("errors", res);

    out.print(obj);
%>
